<!DOCTYPE html>
<html>
<head>
	<title>内置渲染指令</title>
</head>
<body>
	<div ng-app="app">
		<div ng-controller="firstController">
			<p>{{1 + 1}}</p>
			<p ng-bind="1+1"></p>
			<p ng:bind="1+2"></p>
			<p data-ng-bind="1+3"></p>

			<!-- 必须写上{{}} -->
			<p ng-bind-template="{{1+1}}"></p>

			<table ng-class="{color:status}" ng-init="cities = ['上海','北京','苏州','南京']">
				<thead>
					<tr>
						<th>元素</th>
						<th>索引</th>
						<th>头元素</th>
						<th>非头非尾元素</th>
						<th>尾元素</th>
					</tr>
				</thead>

				<tbody>
					<!-- ng-class-even，ng-class-odd的值需要加上引号 -->
					<tr ng-repeat="city in cities">
						<td>{{city}}</td>
						<td>{{$index}}</td>
						<td>{{$first}}</td>
						<td>{{$middle}}</td>
						<td>{{$last}}</td>
					</tr>
				</tbody>
			</table>

			<div ng-include="'other.html'" ></div>
			<!-- 同上 -->
			<div ng-include src="'other.html'" ></div>
		</div>
	</div>

	<script type="text/javascript" src="../angular/angular-1.6.5.min.js"></script>
	<script type="text/javascript" src="app/index.js"></script>
</body>
</html>